import { useSearchParams } from 'react-router-dom';
const Article = () => {
// 第一种传参
  const [params] = useSearchParams();
  const id = params.get('id');
  const name = params.get('name');
  return (
    <div>
      文章页面
      <div>
        {id}:{name}
      </div>
    </div>
  );
};
export default Article;
